package com.example.cs342messenger;

public class Comment implements Comparable{

	private String comment;
	private String sender;
	private String reciever;
	private int num;
	
	public void setComment(String com){
		comment = com;
	}
	
	public void setNum(int n){
		num = n;
	}
	
	public void setUser(String person){
		sender = person;
	}
	
	public void setReciever(String rec){
		reciever= rec;
	}
	
	public String getComment(){
		return comment;
	}
	
	public String getUser(){
		return sender;
	}
	
	public String getReciever(){
		return reciever;
	}
	
	public int getNum(){
		return num;
	}

	@Override
	public int compareTo(Object o) {
		Comment com = (Comment)o;
		if(this.sender.equals(com.getUser())){
			return 1;
		}else{
			return 0;
		}
	}
}
